<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <script>
        window.hdjs = {};
        window.hdjs.base = '../';
        window.hdjs.uploader = 'test/php/uploader.php?';
        window.hdjs.filesLists = 'test/php/filesLists.php?';
    </script>
    <script src="../dist/static/requirejs/require.js"></script>
    <script src="../dist/static/requirejs/config.js"></script>
</head>
<body style="padding: 50px;">
<input id="datetimepicker" class="form-control">
<script>
    require(['hdjs'], function (hdjs) {
        hdjs.datetimepicker('#datetimepicker', {
            timepicker: false,
            format: 'Y-m-d',
            onChangeDateTime: function (dp, $input) {
                console.log($input.val())
            }
        });
    })
</script>
<hr>
<input id="datetimepicker2" class="form-control">
<script>
    require(['hdjs'], function (hdjs) {
        hdjs.datetimepicker('#datetimepicker2', {
            onChangeDateTime: function (dp, $input) {
                console.log($input.val())
            }
        });
    })
</script>
<hr>
Start <input id="date_timepicker_start" value="">
End <input id="date_timepicker_end" value="">
<script>
    require(['hdjs', 'jquery'], function (hdjs, jQuery) {
        hdjs.datetimepicker('#date_timepicker_start',{
            format: 'Y/m/d',
            onShow: function (ct) {
                this.setOptions({
                    maxDate: jQuery('#date_timepicker_end').val() ? jQuery('#date_timepicker_end').val() : false
                })
            },
            timepicker: false
        });
        hdjs.datetimepicker('#date_timepicker_end',{
            format: 'Y/m/d',
            onShow: function (ct) {
                this.setOptions({
                    minDate: jQuery('#date_timepicker_start').val() ? jQuery('#date_timepicker_start').val() : false
                })
            },
            timepicker: false
        });
    })
</script>
<hr>
时间<input id="datetimepicker3" value="">
<script>
    require(['hdjs', 'jquery'], function (hdjs, jQuery) {
        hdjs.datetimepicker('#datetimepicker3',{
            datepicker: false,
            format: 'h:i'
        });
    })
</script>
</body>
</html>